class Customer < ActiveRecord::Base
  attr_accessible :default_address_id, :default_contact_id, :name, :remarks

  belongs_to :default_address, :class_name => 'Address', :foreign_key => 'default_address_id'
  belongs_to :default_contact, :class_name => 'Contact', :foreign_key => 'default_contact_id'

  accepts_nested_attributes_for :default_address
end
